import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'Home',
    component: Home
  },
  {
    path: '/login',
    name: 'Login',
    component: () => import('../views/Login.vue')
  },
  {
    path: '/city',
    name: 'City',
    component: () => import('../views/City.vue')
  },
  {
    path: '/map',
    name: 'Map',
    component: () => import('../views/Map.vue')
  },
  {
    path: '/newhouse',
    name: 'NewHouse',
    component: () => import('../views/NewHouse.vue')
  },
  {
    path: '/secondhouse',
    name: 'SecondHouse',
    component: () => import('../views/SecondHouse.vue')
  },
  {
    path: '/secdetail/:id',
    name: 'SecDetail',
    component: () => import('../views/SecDetail.vue')
  },
  {
    path: '/rentalhouse',
    name: 'RentalHouse',
    component: () => import('../views/RentalHouse.vue')
  },
  {
    path: '/vr',
    name: 'VR',
    component: () => import('../views/VR.vue')
  },
  {
    path: '/message',
    name: 'Message',
    component: () => import('../views/menus/Message.vue')
  },
  {
    path: '/wantbuy',
    name: 'WantBuy',
    component: () => import('../views/menus/WantBuy.vue')
  },
  {
    path: '/wantrent',
    name: 'WantRent',
    component: () => import('../views/menus/WantRent.vue')
  },
  {
    path: '/property',
    name: 'Property',
    component: () => import('../views/menus/Property.vue')
  },
  {
    path: '/bo',
    name: 'Bo',
    component: () => import('../views/menus/Bo.vue')
  },
  // {
  //   path: '/createbo',
  //   name: 'CreateBo',
  //   component: () => import('../views/menus/CreateBo.vue')
  // },
  {
    path: '/tuan',
    name: 'Tuan',
    component: () => import('../views/menus/Tuan.vue')
  },
  {
    path: '/pai',
    name: 'Pai',
    component: () => import('../views/menus/Pai.vue')
  },
  {
    path: '/ji',
    name: 'Ji',
    component: () => import('../views/menus/Ji.vue')
  },
  {
    path: '/ji1',
    name: 'ji1',
    component: () => import('../views/menus/ji1.vue')
  },
  {
    path: '/detail/:id',
    name: 'Detail',
    component: () => import('../views/menus/Detail.vue')
  },
  {
    path: '/inter',
    name: 'Inter',
    component: () => import('../views/menus/Inter.vue')
  },
  {
    path: '/tuandetail/:id',
    name: 'TuanDetail',
    component: () => import('../views/menus/TuanDetail.vue')
  },
  {
    path: '/kaituan/:id',
    name: 'KaiTuan',
    component: () => import('../views/menus/KaiTuan.vue')
  },
  {
    path: '/chat/:id',
    name: 'Chat',
    component: () => import('../views/menus/Chat.vue')
  },
  {
    path: '/huifang/:id',
    name: 'HuiFang',
    component: () => import('../views/menus/HuiFang.vue')
  }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
